//
//  YSY_Game_HeroDetailCollectionViewCell.m
//  GoodManNews
//
//  Created by dllo on 16/1/12.
//  Copyright © 2016年 dllo. All rights reserved.
//

#import "YSY_Game_HeroDetailCollectionViewCell.h"
#import "Masonry.h"
@implementation YSY_Game_HeroDetailCollectionViewCell

- (void)dealloc
{
    [_headV release];
    [_titleL release];
    [_cnNameL release];
    [super dealloc];
    
}
- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        [self createView];
    }
    return self;
}

- (void)createView {
    self.headV = [UIImageView new];
    self.headV.userInteractionEnabled = YES;
    [self.contentView addSubview:self.headV];
    self.headV.backgroundColor  = [UIColor whiteColor];
    [self.headV mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.equalTo(self.contentView);
        make.left.equalTo(self.contentView);
        make.right.equalTo(self.contentView);
        make.height.mas_equalTo(self.contentView.bounds.size.height / 3 * 2);
    }];
    
    self.titleL = [UILabel new];
    self.titleL.userInteractionEnabled = YES;
    self.titleL.textAlignment = NSTextAlignmentCenter;
    [self.contentView addSubview:self.titleL];
    [self.titleL mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.equalTo(self.headV.mas_bottom);
        make.left.equalTo(self.headV);
        make.right.equalTo(self.headV);
        make.height.mas_equalTo(self.contentView.bounds.size.height / 6);
    }];
    
    self.cnNameL = [UILabel new];
    self.cnNameL.textAlignment = NSTextAlignmentCenter;
    [self.contentView addSubview:self.cnNameL];
    [self.cnNameL mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.equalTo(self.titleL.mas_bottom);
        make.left.equalTo(self.titleL);
        make.right.equalTo(self.titleL);
        make.height.mas_equalTo(self.contentView.bounds.size.height / 6);
    }];


    
    
    
}
@end
